"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
const taro_1 = require("@tarojs/taro");
const components_1 = require("@tarojs/components");
const prop_types_1 = require("prop-types");
const classnames_1 = require("classnames");
const Content_1 = require("./Content");
require("./index.scss");
class XCard extends taro_1.Component {
    render() {
        const { data, onClick } = this.props;
        return (<components_1.View className={classnames_1.default('card', { 'card-vertical': data.status === 0, 'card-horizontal': data.status === 1 })} onClick={onClick}>
                {<components_1.Image src={data.banner[0].pathName} className='image' mode='widthFix'/>}
                <components_1.View style={{ flex: 'auto' }}>
                    <Content_1.default data={data}/>
                </components_1.View>
            </components_1.View>);
    }
}
XCard.propTypes = {
    data: prop_types_1.default.object,
    onClick: prop_types_1.default.func
};
XCard.defaultProps = {
    data: {},
    onClick: () => { }
};
exports.default = XCard;
//# sourceMappingURL=index.jsx.map